let db = require('../db.js');

//获取客户端最新版本
exports.getLastVersion  = async function () {
    let sql=`
    SELECT 
    num,
    content,
    url,
    createdAt
    FROM  version  where isdelete ='n' order by createdAt desc limit 1
    `
    let data = await db.query(sql);
    return data[0];
}